package org.eclipse.emf.index.omds.core.indexer;

import org.eclipse.emf.common.util.URI;
import org.eclipse.emf.ecore.resource.Resource;
import org.eclipse.emf.index.resource.IndexFeeder;
import org.eclipse.emf.index.resource.ResourceIndexer;
import org.eclipse.emf.index.resource.impl.ResourceIndexerImpl;

public class OMSResourceIndexerJava extends ResourceIndexerImpl implements ResourceIndexer{

	@Override
	public void resourceChanged(URI resource, IndexFeeder feeder) {
		Resource testRes = super.loadResource(resource);
		this.resourceChanged(testRes, feeder);
		super.resourceChanged(resource, feeder);
		
	}

	@Override
	public void resourceDeleted(URI resourceURI, IndexFeeder feeder) {
		// TODO Auto-generated method stub
		
	}
	
	public void resourceChanged(Resource resource, IndexFeeder feeder){
		if(resource != null){
			System.out.println("The resource is loaded.");
		}
		
		else{
			System.err.println("The resource is null.");
		}
	}

}
